package cn.sskxyz.security.resource.web.controller;

import org.springframework.http.ResponseEntity;
import org.springframework.security.core.Authentication;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class ResourceController {

    @RequestMapping("/test")
    public ResponseEntity<String> test() {
        return ResponseEntity.ok("hahaha");
    }

    @RequestMapping("/user")
    public ResponseEntity<Authentication> getUser(Authentication authentication) {
        return ResponseEntity.ok(authentication);
    }
}
